Goto

Collaborating Authors

 ros2 laser scan topic


Exploring ROS2 with wheeled robot – #2 – How to subscribe to ROS2 laser scan topic

Robohub

This is the second chapter of the series "Exploring ROS2 with a wheeled robot". In this episode, you'll learn how to subscribe to a ROS2 topic using ROS2 C . Before anything else, make sure you have the rosject from the previous post, you can copy it from here. Launch the simulation in one webshell and in a different tab, checkout the topics we have available. Our goal is to read the laser data, so create a new file called reading_laser.cpp: